package task1;

import java.util.ArrayList;
import java.util.Scanner;

public class test3 {
    public static void main(String[] args) {
        ArrayList<Integer> array=new ArrayList<>();
        Scanner input=new Scanner(System.in);
        int num;
        while ((num=input.nextInt())!=0){
            array.add(num);
        }


    }
}
